import { http } from "@/utils/http";
import { baseUrlApi } from "./utils";

type homeResult = {
  page: any;
  result: any
};

/** 查询应用方案分类菜单 */
export const getapplicationselpage = () => {
  return http.request<homeResult>("get", baseUrlApi(`/api/backend/applicationversion/selpage`));
};



/** 新增应用方案信息 */
export const applicationinserclass = (data?: object) => {
  return http.request<homeResult>("post", baseUrlApi("/api/backend/applicationversion/inserclass"), { data });
};

/** 修改应用方案信息 */
export const applicationgrclass = (data?: object) => {
  return http.request<homeResult>("post", baseUrlApi("/api/backend/applicationversion/grclass"), { data });
};


/** 删除应用方案信息 */
export const applicationdelinfo = (userid?: string | number) => {
  return http.request<homeResult>("delete", baseUrlApi(`/api/backend/applicationversion/delinfo/${userid}`));
};


// 应用列表
export const applicationselyylb = (data?: object) => {
  return http.request<homeResult>("post", baseUrlApi("/api/backend/applicationversion/selyylb"), { data });
};



/** 应用列表详情 */
export const qpapplicationversionselpage = (data?: object) => {
  return http.request<homeResult>("post", baseUrlApi("/api/backend/applicationversion/qpapplicationversionselpage"), { data });
};

/** 应用列表详情保存 */
export const updateclassinfo = (data?: object) => {
  return http.request<homeResult>("post", baseUrlApi("/api/backend/applicationversion/updateclassinfo"), { data });
};


/** 保存方框图坐标等信息 */
export const savepicinfo = (data?: object) => {
  return http.request<homeResult>("post", baseUrlApi("/api/backend/applicationversion/savepicinfo"), { data });
};


/** 删除方框图 */
export const delappversionpic = (userid?: string | number) => {
  return http.request<homeResult>("delete", baseUrlApi(`/api/backend/applicationversion/delappversionpic/${userid}`));
};



/** 首页下侧展示菜单查询 */
export const applicationversionselhopa = () => {
  return http.request<homeResult>("get", baseUrlApi(`/api/backend/applicationversion/selhopa`));
};

/** 首页下侧展示菜单编辑 */
export const applicationversioninserthopa = (data?: object) => {
  return http.request<homeResult>("post", baseUrlApi("/api/backend/applicationversion/inserthopa"), { data });
};